home *** CD-ROM | disk | FTP | other *** search
/ Gigarom 1 / Gigarom Macintosh Archives (Quantum Leap)(CDRM1080320)(1993).iso / FILES / DEV / A-B / About... 2.1.cpt / About… 2.1 Demo Globals.p next >
Text File  |  1992-01-01  |  3KB  |  153 lines

  1. unit Globals;
  2.  
  3.  
  4. interface
  5.  
  6.  
  7.     uses
  8.         About;                        { …my unit! }
  9.  
  10.  
  11.  
  12.     const
  13.         maxDemoWindows = 12;
  14.  
  15.         SharewareMsg = 'About… is $10 SHAREWARE.';
  16.         CopyrightMsg = '© 1989-92 by Jon Wind';
  17.  
  18.         AboutDemoID = 129;
  19.         HelpTEXTID = 128;
  20.         AboutTEXTID = 1000;
  21.         IconID = 1000;
  22.         WinProcMenuID = 255;
  23.         popupSICNid = 128;
  24.         On = 1;
  25.         Off = 0;
  26.         Disable = 255;
  27.         goNext = 1;
  28.         goPrev = -1;
  29.  
  30. { *** The constants below were added to be used in the case statements.}
  31.         enterKey = 3;
  32.         BS = 8;
  33.         tabKey = 9;
  34.         CR = 13;
  35.         leftArrow = 28;
  36.         rightArrow = 29;
  37.         upArrow = 30;
  38.         downArrow = 31;
  39.         num0 = 48;
  40.         num1 = 49;
  41.         num2 = 50;
  42.         num3 = 51;
  43.         num4 = 52;
  44.         num5 = 53;
  45.         num6 = 54;
  46.         num7 = 55;
  47.         num8 = 56;
  48.         num9 = 57;
  49.         upperC = 67;
  50.         upperV = 86;
  51.         upperX = 88;
  52.         lowerC = 99;
  53.         lowerV = 118;
  54.         lowerX = 120;
  55.  
  56.         dBoxWWin = 1;
  57.         dPlainWWin = 2;
  58.         dAltWWin = 3;
  59.         dNoGrowWin = 4;
  60.         dRDocWWin = 5;
  61.         dMovableWin = 6;
  62.  
  63.         dTopEd = 5;
  64.         dLeftEd = 7;
  65.         dBottomEd = 9;
  66.         dRightEd = 11;
  67.         dSetRectBtn = 12;
  68.  
  69.         dWinProcPop = 14;
  70.  
  71.         dTitleEd = 16;
  72.         dMsgChk = 17;
  73.         dMsgEd = 18;
  74.  
  75.         dCenterRad = 19;
  76.         dTopWinRad = 20;
  77.         dMainMonRad = 21;
  78.  
  79.         dIconChk = 22;
  80.         dStylChk = 23;
  81.         dCopyChk = 24;
  82.         dCloseChk = 25;
  83.         dEquivChk = 26;
  84.         dModalChk = 27;
  85.  
  86.         dAboutBtn = 28;
  87.  
  88.         dSetRectBtnStr = '<-Set Rect';
  89.         dSetRectBtnStr2 = 'Click';
  90.         dSetRectBtnStr3 = 'OK';
  91.         dSetRectBtnStr4 = 'Drag';
  92.  
  93.  
  94.     type
  95.         ColorSpecPtr = ^ColorSpec;
  96.         ColorSpec = record
  97.                 value: Integer;                         {index or other value}
  98.                 rgb: RGBColor;                            {true color}
  99.             end;
  100.  
  101.         CSpecArray = array[0..0] of ColorSpec;
  102.  
  103.         CCTabPtr = ^CtlCTab;
  104.         CCTabHandle = ^CCTabPtr;
  105.         CtlCTab = record
  106.                 ccSeed: LongInt;                {reserved}
  107.                 ccRider: Integer;            {see what you have done - reserved}
  108.                 ctSize: Integer;                {usually 3 for controls}
  109.                 ctTable: array[0..3] of ColorSpec;
  110.             end;
  111.  
  112.         AuxWinPtr = ^AuxWinRec;
  113.         AuxWinHandle = ^AuxWinPtr;
  114.         AuxWinRec = record
  115.                 awNext: AuxWinHandle;        {handle to next AuxWinRec}
  116.                 awOwner: WindowPtr;         {ptr to window }
  117.                 awCTable: CTabHandle;        {color table for this window}
  118.                 dialogCItem: Handle;        {handle to dialog manager structures}
  119.                 awFlags: LongInt;            {reserved for expansion}
  120.                 awReserved: CTabHandle;     {reserved for expansion}
  121.                 awRefCon: LongInt;            {user Constant}
  122.             end;
  123.  
  124.         PopUpMenu = record
  125.                 MenuHndl: MenuHandle;
  126.                 promptRect, PopUpRect: Rect;
  127.                 PopDItem, Selected, menuID: Integer;
  128.                 canInvert: Boolean;
  129.             end;
  130.  
  131.         DemoVars = record
  132.                 WinRect: Rect;
  133.                 WinProc, Center: Integer;
  134.                 Msg, ShowIcon, Style, CopyIt, Close, Keys, Modal: Boolean;
  135.                 MsgText, TitleText: Str255;
  136.             end;
  137.  
  138.  
  139.     var
  140.         AboutStuff: AboutRec;
  141.         CrossCurs: CursHandle;            { cross cursor handle }
  142.         MainDlgPtr: DialogPtr;                    { main dialog box pointer }
  143.         DemoWinPtr: array[1..maxDemoWindows] of WindowPtr;
  144.         zVar: DemoVars;
  145.         ramRect: Rect;
  146.         Finished: Boolean;
  147.         lastClick, ramDemand, ramFree: longint;
  148.         WinTypePop: PopUpMenu;
  149.  
  150.  
  151. implementation
  152.  
  153. end.